package cn.org.eshow.service;

import cn.org.eshow.bean.query.WithdrawAccountQuery;
import cn.org.eshow.common.page.Page;
import cn.org.eshow.model.User;
import cn.org.eshow.model.WithdrawAccount;

import javax.jws.WebService;
import java.util.List;

@WebService
public interface WithdrawAccountManager extends GenericManager<WithdrawAccount, Integer> {

    List<WithdrawAccount> list(WithdrawAccountQuery query);

    Page<WithdrawAccount> search(WithdrawAccountQuery query);

    /**
     * 获取我的提现账号信息
     *
     * @param user
     * @return
     */
    WithdrawAccount mine(User user);

    /**
     * 更新提现账号信息
     *
     * @param old  旧提现账号信息
     * @param withdrawAccount 新提现账号信息
     * @return
     */
    WithdrawAccount update(WithdrawAccount old, WithdrawAccount withdrawAccount);

    WithdrawAccount check(WithdrawAccountQuery query);

    Long count(WithdrawAccountQuery query);
}